package com.softa.web.common.controller;

import com.baomidou.kisso.SSOHelper;
import com.softa.common.sysconfig.support.Result;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * description goes here.
 *
 * @author 杨磊
 * @date 2019/5/26 16:23
 * @since 1.0
 **/
@RestController
@RequestMapping("/logout")
public class LogoutController {

    @GetMapping()
    public Result logout(HttpServletRequest request, HttpServletResponse response) {
        SSOHelper.clearLogin(request, response);
        return new Result();
    }

}
